<HTML
><HEAD
><TITLE
>GrReadArea()</TITLE
><META
NAME="GENERATOR"
CONTENT="Modular DocBook HTML Stylesheet Version 1.61
"><LINK
REL="HOME"
TITLE="Nano-X Library API"
HREF="index.html"><LINK
REL="UP"
TITLE="Nano-X Function Reference"
HREF="ch2.html"><LINK
REL="PREVIOUS"
TITLE="GrRaiseWindow()"
HREF="nxapi_GrRaiseWindow.html"><LINK
REL="NEXT"
TITLE="GrRect()"
HREF="nxapi_GrRect.html"></HEAD
><BODY
CLASS="REFENTRY"
><DIV
CLASS="NAVHEADER"
><TABLE
WIDTH="100%"
BORDER="0"
CELLPADDING="0"
CELLSPACING="0"
><TR
><TH
COLSPAN="3"
ALIGN="center"
>Nano-X Library API</TH
></TR
><TR
><TD
WIDTH="10%"
ALIGN="left"
VALIGN="bottom"
><A
HREF="nxapi_GrRaiseWindow.html"
>Prev</A
></TD
><TD
WIDTH="80%"
ALIGN="center"
VALIGN="bottom"
></TD
><TD
WIDTH="10%"
ALIGN="right"
VALIGN="bottom"
><A
HREF="nxapi_GrRect.html"
>Next</A
></TD
></TR
></TABLE
><HR
ALIGN="LEFT"
WIDTH="100%"></DIV
><H1
><A
NAME="NXAPI.GRREADAREA"
><TT
CLASS="FUNCTION"
>GrReadArea()</TT
></A
></H1
><DIV
CLASS="REFNAMEDIV"
><A
NAME="AEN5937"
></A
><H2
>Name</H2
><TT
CLASS="FUNCTION"
>GrReadArea()</TT
>&nbsp;--&nbsp;Read pixel data from a drawable</DIV
><DIV
CLASS="REFSYNOPSISDIV"
><A
NAME="AEN5941"
></A
><H2
>Synopsis</H2
><DIV
CLASS="FUNCSYNOPSIS"
><A
NAME="AEN5942"
></A
><P
></P
><P
><CODE
><CODE
CLASS="FUNCDEF"
>  void               <B
CLASS="FSFUNC"
>  GrReadArea            </B
></CODE
>( GR_DRAW_ID         <VAR
CLASS="PDPARAM"
> id                    </VAR
>,  GR_COORD           <VAR
CLASS="PDPARAM"
> x                     </VAR
>,  GR_COORD           <VAR
CLASS="PDPARAM"
> y                     </VAR
>,  GR_SIZE            <VAR
CLASS="PDPARAM"
> width                 </VAR
>,  GR_SIZE            <VAR
CLASS="PDPARAM"
> height                </VAR
>,  GR_PIXELVAL *      <VAR
CLASS="PDPARAM"
> pixels                </VAR
>);</CODE
></P
><P
></P
></DIV
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN5958"
></A
><H2
>Description</H2
><P
>    This function reads a rectangle of pixel data from the specified
    drawable into the caller supplied pixel buffer. The pixel data
    is read from a rectangular region at position
    (<TT
CLASS="PARAMETER"
><I
>x</I
></TT
>, <TT
CLASS="PARAMETER"
><I
>y</I
></TT
>) of size
    (<TT
CLASS="PARAMETER"
><I
>width</I
></TT
>, <TT
CLASS="PARAMETER"
><I
>height</I
></TT
>).
    </P
><DIV
CLASS="NOTE"
><P
></P
><TABLE
CLASS="NOTE"
WIDTH="100%"
BORDER="0"
><TR
><TD
WIDTH="25"
ALIGN="CENTER"
VALIGN="TOP"
><IMG
SRC="./stylesheet-images/note.gif"
HSPACE="5"
ALT="Note"></TD
><TD
ALIGN="LEFT"
VALIGN="TOP"
><P
>    If the drawable is a window, then the pixel data returned will
    be pixel values from the appropiate position on the screen. If
    another window covers the specified window, then the visible
    window's image will be returned. If the window
    <TT
CLASS="PARAMETER"
><I
>wid</I
></TT
> is unmapped or partially outside a
    window boundary, black pixels will be returned in the nonvisible
    section of the area.
    </P
></TD
></TR
></TABLE
></DIV
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN5968"
></A
><H2
>Parameters</H2
><DIV
CLASS="INFORMALTABLE"
><A
NAME="AEN5970"
></A
><P
></P
><TABLE
BORDER="1"
CLASS="CALSTABLE"
><THEAD
><TR
><TH
WIDTH="25%"
ALIGN="LEFT"
VALIGN="TOP"
>Type</TH
><TH
WIDTH="25%"
ALIGN="LEFT"
VALIGN="TOP"
>Name</TH
><TH
WIDTH="50%"
ALIGN="LEFT"
VALIGN="TOP"
>Description</TH
></TR
></THEAD
><TBODY
><TR
><TD
WIDTH="25%"
ALIGN="LEFT"
VALIGN="TOP"
><A
HREF="nxstruct_GR_DRAW_ID.html"
><SPAN
CLASS="TYPE"
>GR_DRAW_ID</SPAN
></A
></TD
><TD
WIDTH="25%"
ALIGN="LEFT"
VALIGN="TOP"
><TT
CLASS="PARAMETER"
><I
>id</I
></TT
></TD
><TD
WIDTH="50%"
ALIGN="LEFT"
VALIGN="TOP"
>The ID of the drawable to red pixel data from. </TD
></TR
><TR
><TD
WIDTH="25%"
ALIGN="LEFT"
VALIGN="TOP"
><A
HREF="nxstruct_GR_COORD.html"
><SPAN
CLASS="TYPE"
>GR_COORD</SPAN
></A
></TD
><TD
WIDTH="25%"
ALIGN="LEFT"
VALIGN="TOP"
><TT
CLASS="PARAMETER"
><I
>x</I
></TT
></TD
><TD
WIDTH="50%"
ALIGN="LEFT"
VALIGN="TOP"
>The X coordinate of the read rectangle, relative to
        the drawable. </TD
></TR
><TR
><TD
WIDTH="25%"
ALIGN="LEFT"
VALIGN="TOP"
><A
HREF="nxstruct_GR_COORD.html"
><SPAN
CLASS="TYPE"
>GR_COORD</SPAN
></A
></TD
><TD
WIDTH="25%"
ALIGN="LEFT"
VALIGN="TOP"
><TT
CLASS="PARAMETER"
><I
>y</I
></TT
></TD
><TD
WIDTH="50%"
ALIGN="LEFT"
VALIGN="TOP"
>The Y coordinate of the read rectangle, relative to
        the drawable. </TD
></TR
><TR
><TD
WIDTH="25%"
ALIGN="LEFT"
VALIGN="TOP"
><A
HREF="nxstruct_GR_SIZE.html"
><SPAN
CLASS="TYPE"
>GR_SIZE</SPAN
></A
></TD
><TD
WIDTH="25%"
ALIGN="LEFT"
VALIGN="TOP"
><TT
CLASS="PARAMETER"
><I
>width</I
></TT
></TD
><TD
WIDTH="50%"
ALIGN="LEFT"
VALIGN="TOP"
>The width of the read rectangle, relative to the
        drawable. </TD
></TR
><TR
><TD
WIDTH="25%"
ALIGN="LEFT"
VALIGN="TOP"
><A
HREF="nxstruct_GR_SIZE.html"
><SPAN
CLASS="TYPE"
>GR_SIZE</SPAN
></A
></TD
><TD
WIDTH="25%"
ALIGN="LEFT"
VALIGN="TOP"
><TT
CLASS="PARAMETER"
><I
>height</I
></TT
></TD
><TD
WIDTH="50%"
ALIGN="LEFT"
VALIGN="TOP"
>The height of the read rectangle, relative to the
        drawable. </TD
></TR
><TR
><TD
WIDTH="25%"
ALIGN="LEFT"
VALIGN="TOP"
><A
HREF="nxstruct_GR_PIXELVAL.html"
><SPAN
CLASS="TYPE"
>GR_PIXELVAL*</SPAN
></A
></TD
><TD
WIDTH="25%"
ALIGN="LEFT"
VALIGN="TOP"
><TT
CLASS="PARAMETER"
><I
>pixels</I
></TT
></TD
><TD
WIDTH="50%"
ALIGN="LEFT"
VALIGN="TOP"
>Pointer to a caller supplied area of memory to read
        the pixel data into.</TD
></TR
></TBODY
></TABLE
><P
></P
></DIV
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN6023"
></A
><H2
>See Also</H2
><P
>      <A
HREF="nxapi_GrArea.html"
>            <TT
CLASS="FUNCTION"
>GrArea()</TT
></A
>, 
      <A
HREF="nxapi_GrCopyArea.html"
>            <TT
CLASS="FUNCTION"
>GrCopyArea()</TT
></A
>. 
    </P
></DIV
><DIV
CLASS="NAVFOOTER"
><HR
ALIGN="LEFT"
WIDTH="100%"><TABLE
WIDTH="100%"
BORDER="0"
CELLPADDING="0"
CELLSPACING="0"
><TR
><TD
WIDTH="33%"
ALIGN="left"
VALIGN="top"
><A
HREF="nxapi_GrRaiseWindow.html"
>Prev</A
></TD
><TD
WIDTH="34%"
ALIGN="center"
VALIGN="top"
><A
HREF="index.html"
>Home</A
></TD
><TD
WIDTH="33%"
ALIGN="right"
VALIGN="top"
><A
HREF="nxapi_GrRect.html"
>Next</A
></TD
></TR
><TR
><TD
WIDTH="33%"
ALIGN="left"
VALIGN="top"
><TT
CLASS="FUNCTION"
>GrRaiseWindow()</TT
></TD
><TD
WIDTH="34%"
ALIGN="center"
VALIGN="top"
><A
HREF="ch2.html"
>Up</A
></TD
><TD
WIDTH="33%"
ALIGN="right"
VALIGN="top"
><TT
CLASS="FUNCTION"
>GrRect()</TT
></TD
></TR
></TABLE
></DIV
></BODY
></HTML
>